/*
 * Singularity Engine
 * Copyright (C) 2010 Vyacheslav Vorobyov, All rights reserved.
 * See LICENSE for full license information.
 */
package org.singularity.bom;

/**
 * TODO Describe this entity!
 * @author vjache
 */
public abstract class BooleanOperator
{
	public static enum OpCode
	{
		AND,
		OR,
		NOT,
		PREDICATE, 
		TRUE;
	}
	
	public static interface Visitor
	{
		void onAnd(And aOperator);
		void onOr(Or aOperator);
		void onNot(Not aOperator);
		void onPredicate(Predicate aOperator);
		void onTrue(True aOperator);
	}

	private OpCode _opCode;

	/**
	 * 
	 */
	protected BooleanOperator(OpCode aOperatorCode)
	{
		_opCode = aOperatorCode;
	}

	public OpCode getOperatorCode()
	{
		return _opCode;
	}
	
	public abstract void visit(Visitor aVisitor);
}
